import React from 'react';
import s from './style.module.less'
import { NavBar } from 'react-vant';
import { useNavigate } from 'react-router-dom';

const Header = ({ title="标题" }) => {
    const navigate=useNavigate()
    
  return (
    <div className={s.headerWarp}>
      <div className={s.block}>
        <NavBar
        className={s.header}
          title={title}
          onClickLeft={() => navigate()}
        />
      </div>
    </div>
  );
}

export default Header;